<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8">
	<title>flex-direction: row-reverse</title>
</head>
<style>

.flex-container {
	display: -webkit-flex;
	display: flex;
	-webkit-flex-direction: row-reverse;
	flex-direction: row-reverse;
	width: 600px;
	height: 250px;
	background-color: lightgrey;
}

.flex-item {
	background-color: cornflowerblue;
	width: 100px;
	height: 100px;
	margin: 10px;
}
</style>
<body>

flex-direction 属性指定了弹性子元素在父容器中的位置。<br>
	row：			横向从左到右排列（左对齐），默认的排列方式。<br>
	row-reverse：	反转横向排列（右对齐，从后往前排，最后一项排在最前面。<br>
	column：		纵向排列。<br>
	column-reverse：反转纵向排列，从后往前排，最后一项排在最上面。<br><br>

<div class="flex-container">
	<div class="flex-item">flex item 1</div>
	<div class="flex-item">flex item 2</div>
	<div class="flex-item">flex item 3</div>
	<!-- 如果弹性子元素太多，总宽度超出弹性容器的宽度，那么弹性子元素的宽度会被压缩 -->
	<!-- <div class="flex-item">flex item 1</div>
	<div class="flex-item">flex item 2</div>
	<div class="flex-item">flex item 3</div>
	<div class="flex-item">flex item 4</div> -->
</div>

</body>
</html>
